<template>
  <div class="demo-image__preview">
    <el-image
      style="width: 100px; height: 100px"
      :src="imgList"
      :preview-src-list="imgList"
    >
    </el-image>
  </div>
</template>

<script>
export default {
  name: "PreviewImage",
  props: {
    srcList: {
      type: Array,
      default: () => [],
    },
  },
  data() {
    return {
      imgList: [],
    };
  },
  created() {
    // if (this.srcList && this.srcList.length > 0) {
    //   this.srcList.map(item => {
    //     this.imgList.push(item.url)
    //   })
    // }
  },
};
</script>
